Ext.define('byb.view.grid.system.AdmLog',{
    alias:'widget.sysmgr_logManagerGrid',
    extend:"byb.view.grid.BaseGridPanel",
    store:'system.AdmLog',
    buildColumns:function(){
        return [
                { text: 'ID',  dataIndex: 'id', hidden:true},
                { text: '姓名',  dataIndex: 'username', width:80 },
                { text: '来源',  dataIndex: 'source', width: 60 },
                { text: '链接',  dataIndex: 'url', width: 120 },
                { text: '描述',  dataIndex: 'description',width:120 },
                { text: '记录时间',  dataIndex: 'logTime',width:60 }
              ];
    },
    listeners : {
    	itemdblclick :function(ctx,record,item,index,e,eOpts ){
    		var gridPanel = Ext.ComponentQuery.query('sysmgr_logManagerGrid')[0];
    		var selectionModel = gridPanel.getSelectionModel();
    		if (selectionModel.hasSelection()) {
    			var view =  Ext.widget("admLogView");
    			var records = selectionModel.getSelection()[0];
      			view.down("form").loadRecord(records);
    		}
    	}
    }
});